<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        [v-cloak]{
            display: none;
            color: red;
        }
    </style>
</head>
<body>
    <div id="app"></div>
    <template id="my-app">
        <h2 v-pre>{{message}}</h2>
        <!-- v-pre指令，不解析，直接输出 -->
        <h2 v-cloak>{{message}}</h2>
        <!-- v-cloak指令，解析完成后，再显示 -->
    </template>

    <script src="https://unpkg.com/vue@3/dist/vue.global.js"></script>
    <script>
        const App = {
            template:'#my-app',
            data () {
                return {
                    message:'Hello World'
                }
            },
        }
        Vue.createApp(App).mount('#app')
    </script>
</body>
</html>